DisplayCutoutCompat
Represents the area of the display that is not functional for displaying content.
DisplayCutoutCompat
instances are immutable.
Constructors
Link copied to clipboard
Creates a DisplayCutout instance.
constructor(@NonNull safeInsets: @NonNull Insets, @Nullable boundLeft: @Nullable Rect, @Nullable boundTop: @Nullable Rect, @Nullable boundRight: @Nullable Rect, @Nullable boundBottom: @Nullable Rect, @NonNull waterfallInsets: @NonNull Insets)
Creates a DisplayCutout instance.
constructor(@NonNull safeInsets: @NonNull Insets, @Nullable boundLeft: @Nullable Rect, @Nullable boundTop: @Nullable Rect, @Nullable boundRight: @Nullable Rect, @Nullable boundBottom: @Nullable Rect, @NonNull waterfallInsets: @NonNull Insets, @Nullable cutoutPath: @Nullable Path)
Creates a DisplayCutout instance.
Functions
Link copied to clipboard
Returns a list of
Rect
s, each of which is the bounding rectangle for a non-functional area on the display.Link copied to clipboard
Returns a Path that contains the cutout paths of all sides on the display.
Link copied to clipboard
Returns the inset from the bottom which avoids the display cutout in pixels.
Link copied to clipboard
Returns the inset from the left which avoids the display cutout in pixels.
Link copied to clipboard
Returns the inset from the right which avoids the display cutout in pixels.
Link copied to clipboard
Returns the inset from the top which avoids the display cutout in pixels.
Link copied to clipboard
Returns the insets representing the curved areas of a waterfall display.